#include <iostream>
#include <string>
#include <cstring>
#include <cstdio>
#include <cstdlib>
#include <algorithm>
#include <vector>
#include <map>
#include <set>
#define s(i) scanf("%d", &i)
#define sl(i) scanf("%lld", &i)
#define SET(v, i) memset(v, i, sizeof(v))
#define DIM 2
#define MAXN 505
#define MAXM 100005
#define MOD 1000000007
using namespace std;
typedef long long ll;

ll powmod(int a, ll n){
    int p = 1;
    while (n){
        if (n & 1) p = (ll(p)*a)%MOD;
        if (n /= 2) a = (ll(a)*ll(a))%MOD;
    }
    return p;
}

int calc(int n){
    int inv25 = powmod(25, MOD - 2);
    int k = (n+1)/2;
    int p26 = powmod(26, k);
    int ans = 52ll * (p26-1) % MOD * inv25 % MOD;
    if (n & 1)
        ans = (ans + MOD - p26) % MOD;
    return ans;
}

int main()
{
    freopen("TAPALIN.txt","r", stdin);
    int t;
    ll n;
    s(t);
    while (t--){
        sl(n);
        cout << calc(n) << endl;
    }
    return 0;
}
